var anan = {
beautyTime(num){
return num < 10 ? ("0" + num ) : num;
}
}

Date.prototype.changeTime = function(){
var now = this;
var y = now.getFullYear();
var m = anan.beautyTime(now.getMonth()+1);
var d = anan.beautyTime(now.getDate());
var h =  anan.beautyTime(now.getHours());
var mm = anan.beautyTime(now.getMinutes());
var s =  anan.beautyTime(now.getSeconds());
var str = '日一二三四五六';
var week = str[now.getDay()];
return `${y}-${m}-${d} ${h}:${mm}:${s} 周${week}`
}